AddressBookData Class
Used to manage Address Book fields that store multiple values, such as phone and fax numbers.
More information available in parent classes: Object
Example
The AddressBookData class can be used to get more information about a field ( AddressBookContact properties). The Name method returns the property it represents. The Label method will return what kind of property it is, like Home, Work, etc. The Label property is relevant only for AddressBookData objects that can contain multiple values.
This example gets the user's phone numbers and displays them in a two-column ListBox. The first column displays the label ("Home", "Work", "Mobile", etc.) and the second column shows the phone number.
Dim data as AddressBookData
Dim c,i as Integer
data = Book.CurrentUser.PhoneNumbers
c=Data.count-1
If data.Count > 0 then
For i=0 to c
ListBox1.Addrow Data.Label(i)
ListBox1.Cell(i,1)=Data.Value(i)
next
Else
MsgBox "No phone numbers!"
End if
This method uses the Value method to get the current user's first email address.
Dim myContact as AddressBookContact
book= System.AddressBook
myContact=Book.CurrentUser
MsgBox myContact.emailAddresses.Value(0)
See Also
AddressBook, AddressBookAddress, AddressBookContact, AddressBookGroup, AddressBookRecord classes.